﻿using System.ComponentModel.DataAnnotations;

namespace Md.Api.Model.Manage.SysRole.Request;
/// <summary>
/// 添加系统角色请求实体
/// </summary>
public class RequestInsertSysRoleModel : RequestBaseModel
{
    /// <summary>
    /// 角色名称
    /// </summary>
    [Required(ErrorMessage = "角色名称不能为空")]
    public string? RoleName { get; set; }
    /// <summary>
    /// 角色权限字符串
    /// </summary>
    [Required(ErrorMessage = "角色权限字符串不能为空")]
    public string? RoleKey { get; set; }
    /// <summary>
    /// 显示顺序
    /// </summary>
    public int RoleSort { get; set; }
    /// <summary>
    /// 数据范围（1：全部数据权限 2：自定数据权限 3：本部门数据权限 4：本部门及以下数据权限）
    /// </summary>
    public string? DataScope { get; set; }
    /// <summary>
    /// 菜单树选择项是否关联显示（1:）
    /// </summary>
    public int MenuCheckStrictly { get; set; }
    /// <summary>
    /// 部门树选择项是否关联显示
    /// </summary>
    public int DeptCheckStrictly { get; set; }
    /// <summary>
    /// 角色状态（0正常 1停用）
    /// </summary>
    [Required(ErrorMessage = "角色状态为空"), StringLength(1, ErrorMessage = "角色状态长度为1")]
    public string? Status { get; set; }
    /// <summary>
    /// 备注
    /// </summary>
    public string? Remark { get; set; }
    /// <summary>
    /// 菜单编号数组
    /// </summary>
    public long[]? MenuIds { get; set; }
}